package com.obj;

public class ObjMethod implements Cloneable{
	public static void main(String[] args) {

		ObjMethod obj = new ObjMethod();
		ObjMethod obj2 = new ObjMethod();
		System.out.println(obj==obj2);
		try {
			ObjMethod obj1 = (ObjMethod) obj.clone();
			System.out.println(obj1==obj);
			System.out.println(obj.getClass()==obj1.getClass());
			System.out.println(obj.equals(obj1));
			
			System.out.println(obj1.add(1, 2));
		} catch (CloneNotSupportedException e) {
			e.printStackTrace();
		}
	}

	public int add(int a, int b) {
		return a + b;
	}

}
